package com.golang.api.common;

import cn.hutool.core.lang.Snowflake;
import cn.hutool.core.util.IdUtil;

public class SerialCodePrefix {


    public static final String ACTIVITY_ID = "HD";

    public static final String ORDER_ID = "OD";

    public static final String ORDER_ITEM_ID = "OI";


    public SerialCodePrefix() {
    }

    public static String splice(String prefix) {
        return splice(prefix, IdUtil.getSnowflake());
    }

    public static String splice(String prefix, Snowflake snowflake) {
        return splice(prefix, snowflake.nextIdStr());
    }

    public static String splice(String prefix, String code) {
        return prefix + code;
    }



}
